﻿<%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="WebApplication1._Default" %>

<asp:Content ID="BodyContent" ContentPlaceHolderID="MainContent" runat="server">
    <style>
        td{
            width:250px;
            text-align:center;
        }
        th{
            text-align:center;
        }
    </style>
    <asp:Button Text="添加" runat="server" ID="btnAdd" OnClick="btnAdd_Click" />
    <asp:GridView runat ="server" ID ="gv3" AutoGenerateColumns="false" OnRowDeleting="gv3_RowDeleting" OnRowUpdating="gv3_RowUpdating" OnRowCancelingEdit="gv3_RowCancelingEdit" OnRowEditing="gv3_RowEditing">    
        <Columns>
            <asp:BoundField DataField="Id" HeaderText="Id" />
            <asp:BoundField DataField="ProductName" HeaderText="商品名称" />
            <asp:BoundField DataField="ShortDesc" HeaderText="商品简介" />
            <asp:BoundField DataField="Remarks" HeaderText="备注" />
            <asp:CommandField ShowCancelButton="true" ShowDeleteButton="true" ShowEditButton="true" HeaderText="操作" />
        </Columns>

    </asp:GridView>

</asp:Content>
